<template>
    <div class="box">
        <div class="gray-box"></div>
        <van-radio-group v-model="radioDelivery">
            <van-radio name="1">
                <img slot="icon" slot-scope="props" :src="props.checked ? activeIcon : inactiveIcon">
                快递邮寄
            </van-radio>
            <div class="prompt">
                1.运费10元，满200元包邮 <br>
                2.默认发圆通快递，西藏、新疆等偏远地区邮费另计，详情请咨
                询在线客服
            </div>
            <div class="gray-box"></div>
            <van-radio name="2">
                <img slot="icon" slot-scope="props" :src="props.checked ? activeIcon : inactiveIcon">
                到店自提
            </van-radio>
        </van-radio-group>
        <button @click="confirmOrder">确定</button>
    </div>
</template>

<script>
    import activeIcon from '@//assets/images/icon-active.png'
    import inactiveIcon from '@//assets/images/icon-inactive.png'
    export default {
        name: "modifyInfo",
        data(){
            return{
                radioDelivery:"",//配送方式
                inactiveIcon,
                activeIcon,
                username:'张晓明',
                phone:'1514557111'
            }
        },
        methods:{
            confirmOrder(){
                //确认单
                let id = this.radioDelivery
                this.$router.push(`/product/confirmOrder/${id}`)
            },
        },
        created() {
            this.radioDelivery = this.$route.params.id
        }
    }
</script>

<style lang="scss" scoped>
    @import "@/assets/css/public";
.box{
    background-color: $gray_bg;
    .van-radio{
        display: flex;
        justify-content: space-between;
        flex-direction: row-reverse;
        align-items: center;
        height: vw(100);
        padding: 0 vw(40);
        color: #333;
        font-size: vw(32);
        background-color: #fff;
        img{
            width: vw(24);
        }
    }
    button{
        display: block;
        width:vw(710);
        height:vw(78);
        margin: vw(100) auto 0;
        background: $gradientBg;
        border-radius:39px;
        font-size: vw(32);
        color: #fff;
    }
    .prompt {
        padding: vw(20) vw(40);
        font-size:vw(24);
        font-weight:400;
        color:rgba(179,179,179,1);
        line-height:vw(36);
    }
}
</style>
